import assemble_results_predict
import os


cddnames = ['kaggle_stage2_candidates_v4.pkl', ]
for cddname in cddnames:
    assemble_results_predict.main(
        candidate_file='../../data/tmp_fp_reduction/'+cddname,
        result_files=[
            '../../data/tmp_fp_reduction/kaggle_results/cddv9_fold{i}_{cddname}/cddv9_fold{i}_{cddname}.pkl'.format(i=i, cddname=os.path.splitext(cddname)[0]) for i in range(5)
        ],
        outfile='../../data/reduced_candidates/3dcnn_'+cddname,
    )


cddnames = ['kaggle_stage2_candidates_v10.pkl', ]
for cddname in cddnames:
    assemble_results_predict.main(
        candidate_file='../../data/tmp_fp_reduction/' + cddname,
        result_files=[
            '../../data/tmp_fp_reduction/kaggle_results/cddv15_v2_fold{i}_{cddname}/cddv15_v2_fold{i}_{cddname}.pkl'.format(
                i=i, cddname=
                os.path.splitext(cddname)[0]) for i in range(4)
            ],
        outfile='../../data/reduced_candidates/3dcnn_cddv15_v2_' + cddname,
    )
